﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace _05.TwoKeysDictionary
{
    public class Student
    {
        static Random random = new Random();
        private static string[] allFirstNames = { "Todor", "Asen", "George", "Milen", "Plamen", "Atanas", "Vladimir",
                                                 "Kiril", "Orliv", "Borislav", "Lazar", "Mladen", "Ivan",
                                                 "Qsen", "Hristo", "Dean", "Vasil" };
        private static string[] allLastName = { "Ivanov", "Stoqnov", "Statev", "Mladenov", "Filipov", "Avramov", "Todorov",
                                                "Borisov", "Hristov","Zdravkov"};
        private static string[] allFaculties = { "FH", "FP", "FMI", "FJMC", "FT", "FB", "FCP", "FGG" };

        public string Faculty { get; set; }
        public int FN { get; set; }
        public string Name { get; set; }

        private static T RandomValue<T>(T[] inArray)
        {
            return inArray[random.Next() % inArray.Length];
        }

        public Student()
        {
            Faculty = RandomValue(allFaculties);
            FN = random.Next(10000, 99999);
            Name = RandomValue(allFirstNames) + " " + RandomValue(allLastName);
        }

        public Student(Tuple<string, int, string> tuple)
        {
            Faculty = tuple.Item1;
            FN = tuple.Item2;
            Name = tuple.Item3;
        }
    }
}